//
//  DardMode.swift
//  
//
//  Created by bo wang on 2021/2/2.
//  Copyright © 2021 wangbo. All rights reserved.
//

import Foundation
import UIKit

/*

extension UIWindow {
    
    /// 调整Window的显示模式
    /// - Parameter mode: 夜间模式状态
    func adjustUserInterfaceStyle(_ mode: DarkMode) {
        if #available(iOS 13, *) {
            // 现在总是夜间模式
            overrideUserInterfaceStyle = .dark

            // 自动适配显示模式
//            let window = AppDelegate.shared.window
//            switch mode {
//            case .dark: window?.overrideUserInterfaceStyle = .dark
//            case .light: window?.overrideUserInterfaceStyle = .light
//            case .system: window?.overrideUserInterfaceStyle = .unspecified
//            }
        }
    }
}

 */
